package com.payment.ktb.activity;

import android.os.Bundle;

import com.payment.ktb.constants.Constants;
import com.payment.ktb.utils.SharedPreferencesUtils;
import com.ppdai.loan.PPDLoanAgent;
import com.umeng.analytics.MobclickAgent;

/**
 * Created by syd on 2016/8/3.
 */
public class StartActivity extends BaseActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        MobclickAgent.setScenarioType(mContext, MobclickAgent.EScenarioType.E_UM_NORMAL);

        if (SharedPreferencesUtils.getBoolean(Constants.GOGUIDEACTIVITY, true)) {
            startActivityThenKill(GuideActivity.class);
            SharedPreferencesUtils.putBoolean(Constants.GOGUIDEACTIVITY,false);
        } else {
            startActivityThenKill(SplashActivity.class);
        }

        //
        PPDLoanAgent.getInstance().onLaunchCreate(this);

    }

    @Override
    protected void onResume() {
        super.onResume();
        PPDLoanAgent.getInstance().onLaunchResume(this);
    }
}
